package com.mofang.activity.study;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.LinearLayout;

import com.mofang.R;
import com.mofang.activity.BaseTitleViewActiviey;
import com.mofang.activity.MainActivity;

public class MainStudyActivity extends BaseTitleViewActiviey implements OnClickListener{
	
	private LinearLayout knowledge_market_ly;//市场
	private LinearLayout knowledge_policy_ly;//政策
	private LinearLayout knowledge_house_ly;//住宅
	private LinearLayout knowledge_work_ly;//工作
	private LinearLayout knowledge_business_ly;//商业
	private LinearLayout knowledge_villa_ly;//别墅
	private LinearLayout knowledge_complex_ly;//综合体
	private LinearLayout knowledge_industrialParks_ly;//产业园区
	private LinearLayout knowledge_touristEstate_ly;//旅游地产
	private LinearLayout knowledge_pensionEstate_ly;//养老地产
	private LinearLayout knowledge_other_ly;//其他

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main_knowledge);
		setNavigationTitle("学习");
		
		findView();
		
	}

	private void findView() {
		
		knowledge_market_ly = (LinearLayout) findViewById(R.id.knowledge_market_ly);
		knowledge_market_ly.setOnClickListener(this);
		
		knowledge_policy_ly = (LinearLayout) findViewById(R.id.knowledge_policy_ly);
		knowledge_policy_ly.setOnClickListener(this);
		
		knowledge_house_ly = (LinearLayout) findViewById(R.id.knowledge_house_ly);
		knowledge_house_ly.setOnClickListener(this);
		
		knowledge_work_ly = (LinearLayout) findViewById(R.id.knowledge_work_ly);
		knowledge_work_ly.setOnClickListener(this);
		
		knowledge_business_ly = (LinearLayout) findViewById(R.id.knowledge_business_ly);
		knowledge_business_ly.setOnClickListener(this);
		
		knowledge_villa_ly = (LinearLayout) findViewById(R.id.knowledge_villa_ly);
		knowledge_villa_ly.setOnClickListener(this);
		
		knowledge_complex_ly = (LinearLayout) findViewById(R.id.knowledge_complex_ly);
		knowledge_complex_ly.setOnClickListener(this);
		
		knowledge_industrialParks_ly = (LinearLayout) findViewById(R.id.knowledge_industrialParks_ly);
		knowledge_industrialParks_ly.setOnClickListener(this);
		
		knowledge_touristEstate_ly = (LinearLayout) findViewById(R.id.knowledge_touristEstate_ly);
		knowledge_touristEstate_ly.setOnClickListener(this);
		
		knowledge_pensionEstate_ly = (LinearLayout) findViewById(R.id.knowledge_pensionEstate_ly);
		knowledge_pensionEstate_ly.setOnClickListener(this);
		
		knowledge_other_ly = (LinearLayout) findViewById(R.id.knowledge_other_ly);
		knowledge_other_ly.setOnClickListener(this);
		
		
		
	}

	@Override
	public void onClick(View v) {
		
		Intent intent;
		switch (v.getId()) {
		
		case R.id.knowledge_market_ly:
			
			intent = new Intent(getApplicationContext(), MarketActivity.class);
			startActivity(intent);
			
			break;
		case R.id.knowledge_policy_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
			break;
			
		case R.id.knowledge_house_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
			break;
			
		case R.id.knowledge_work_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
			break;
			
		case R.id.knowledge_business_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
			break;
			
		case R.id.knowledge_villa_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
			break;
			
		case R.id.knowledge_complex_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
		case R.id.knowledge_industrialParks_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
			break;
			
		case R.id.knowledge_touristEstate_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
			break;
			
		case R.id.knowledge_pensionEstate_ly:
			
			intent = new Intent(getApplicationContext(), MainActivity.class);
			startActivity(intent);
			
			break;

		default:
			break;
		}
		
	}


}
